package week04;

import java.util.ArrayList;

public class Listadd {

    public static void main(String[] args) {
    	ArrayList<Fruit> fruitList = new ArrayList<Fruit>();
        Fruit[] fruit = new Fruit[5];
        fruit[0] = new Fruit("lili");
        fruit[1] = new Fruit("LiLi");
        fruit[2] = new Fruit("nini");
        fruit[3] = new Fruit("NiNi");
        fruit[4] = new Fruit("xixi");
        
        for(int i=0;i<fruit.length;i++){
            if(fruitList.contains(fruit[i])==false)
                fruitList.add(fruit[i]);
        }
        for(int i=0;i<fruitList.size();i++)
            System.out.println(fruitList.get(i));
    	}
    }
    
